package cn.tedu.controller;

import cn.tedu.pojo.Car;
import cn.tedu.service.CarService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author :Colin
 * @version 创建时间: 2021/7/21 13:47
 */
@RestController
@RequestMapping("car")
@CrossOrigin
public class CarController {
    @Autowired
    private CarService carService;
    @RequestMapping("update")

    public String update(Car c){
        carService.update(c);
        return "success";

    }
}
